Carbon


GetControlVariant

Header: Controls.h Carbon status: Supported

Returns the variation code specified in the control definition function for a particular control.

ControlVariant GetControlVariant (
    ControlRef theControl
);
Parameter descriptions
theControl

A handle to the control whose variation code you wish to determine.

function result

The variation code for the specified control; see the control defintion IDs in the “Control Manager Constants” section for descriptions of control variation codes.

DISCUSSION

A control definition function can use a variation code to describe variations of the same basic control. For example, all pop-up arrows share the same basic control definition function, which is stored in a resource of type 'CDEF' and has a resource ID of 12. The standard pop-up arrow is large and points to the right; it has a control definition ID of 192. A variation of this is a large, left-pointing arrow, which has a control definition ID of 193. Still another variation, in which the arrow points up, has a control definition ID of 194.

AVAILABILITY

Supported in Carbon. Available in Carbon 1.0.2 and later when running Mac OS 8.1 or later.


© 2000 Apple Computer, Inc. (Last Updated 6/30/2000)